package com.hson.demo.soa.dao.school;

import java.util.List;
import org.springframework.jdbc.core.simple.ParameterizedBeanPropertyRowMapper;
import org.springframework.stereotype.Repository;
import com.hson.demo.soa.dao.BaseDAO;
import com.hson.demo.soa.dto.ClassesDTO;

@Repository("classesDao")
public class ClassesDao extends BaseDAO{
	
	public List<ClassesDTO> listClasses(){
		List<ClassesDTO> list = jdbcTemplate.query("select * from classes",
				ParameterizedBeanPropertyRowMapper.newInstance(ClassesDTO.class));
		
		return list;
	}
	
	
}
